home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Trusted Irix /B 4.0.4
/
Trusted-Irix B-4.0.1.iso
/
dist
/
eoe1.idb
/
usr
/
include
/
sys
/
gfx_kb.h.z
/
gfx_kb.h
Wrap
Text File
|
1992-04-03
|
2KB
|
88 lines
/*
* Keyboard definitions.
*
* $Revision: 1.14 $
*/
#define TERM_NAME "iris_ansi"
#define LAMP_NUMLOCK 0x20
#define LAMP_CAPSLOCK 0x40
#define LAMP_SCROLLLOCK 0x05
#define LAMP_L1 0x09
#define LAMP_L2 0x11
#define LAMP_L3 0x21
#define LAMP_L4 0x41
#define TIME_DELAY1 40000 /* time for kb to reset */
#define TIME_DELAY2 10000 /* time for 2nd config byte to arrive */
/* this works for both old and new keyboards */
#define CONFIG_REQUEST 0x10 /* kb request config bytes code */
/* config byte returned old kb */
#define CONFIG_BYTE_OLDKB 0xaa
/* config byte returned new kb */
#define CONFIG_BYTE_NEWKB 0x6e
/* control bits for new keyboard, low bit = 0 */
#define NEWKB_SHORTBEEP 0x02
#define NEWKB_LONGBEEP 0x04
#define NEWKB_NOCLICK 0x08
#define NEWKB_GETCONFIG 0x10
#define NEWKB_SETDS1 0x20
#define NEWKB_SETDS2 0x40
#define NEWKB_AUTOREPEAT 0x80
/* control bits for new keyboard, low bit = 1 */
#define NEWKB_DS1ANDDS2 0x03
#define NEWKB_SETDS3 0x05
#define NEWKB_SETDS4 0x09
#define NEWKB_SETDS5 0x11
#define NEWKB_SETDS6 0x21
#define NEWKB_SETDS7 0x41
#define NEWKB_OFFDS 0x01 /* disable most DS's */
/* soft keyboard states */
#define STATE_ALT 0x01
#define STATE_CONTROL 0x02
#define STATE_SHIFT 0x04
#define STATE_CAPSLOCK 0x08
#define STATE_NUMLOCK 0x10
/*
* We manage an extended ascii keyboard set with this code. To do this,
* the standard 256 ascii sequence is represented in a standard fashion.
* An addtions will be numerically larger than 256.
*/
#define CODE_BREAK 0x0100 /* break code */
/* constants for the iris keyboard */
#define KBD_BEEPCMD 0x00 /* low bit clear --> beep commands */
#define KBD_LEDCMD 0x01 /* low bit set --> led commands */
#define KBD_RESET 0x10 /* reset the keyboard */
#define KBD_REPLY 0xAA /* reply from keyboard after reset */
/* beep commands */
#define KBD_CLICK 0x08 /* key click: active low */
#define KBD_SHORTBEEP 0x02 /* do a short beep */
#define KBD_LONGBEEP 0x04 /* do a long beep */
/* led commands */
#define KBD_LED0 0x00
#define KBD_LED1 0x02 /* led0 and led1 are inverses */
#define KBD_LED2 0x04
#define KBD_LED3 0x08
#define KBD_LED4 0x10
#define KBD_LED5 0x20
#define KBD_LED6 0x40
#define KBD_LED8 0x80
/* defaults */
#define KBD_BEEPDEFAULT (KBD_BEEPCMD|KBD_CLICK|KBD_SHORTBEEP)
#define KBD_LEDDEFAULT (KBD_LEDCMD|KBD_LED0)
/* For international stuff */
#define US_KBD 0xcc /* AMERICAN/ENGLISH KEYBOARD */
#define ISO_KBD 0xee /* INTERNATIONAL KEYBOARD */